﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;

namespace RSHB.Framework.BLL
{
    public class FileContentProvider : IFileContentProvider
    {
        public string FileName { get; set; }

        public FileContentProvider(string fileName)
        {
            this.FileName = fileName;
        }    

        public Stream LoadFileContent()
        {
            if (!File.Exists(this.FileName))
            {
                return null;
            }
            return (new StreamReader(this.FileName)).BaseStream;
        }
    }
}
